package cn.edu.sdufe.sn20180664257;

import android.content.Intent;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.Toast;

/**
 * 主页的activity以及
 * 实现页面跳转的功能！！！
 */

public class Activity_ch5_1 extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.layout_homework);
    }

//    public void toast1(View view){
        //Toast toast=Toast.makeText(this,"message",Toast.LENGTH_LONG);
        //toast.show();

//        Toast.makeText(this,"message",Toast.LENGTH_LONG).show();
//    }

    public void ch4Activity(View view){
        //第一次作业界面的跳转
        Intent intent = new Intent(this, Activity_ch4_1.class);//第一个参数是上下文，第二个参数是要跳转的activity的类
        startActivity(intent);
    }

    public void ch5Activity(View view){
        //第二次作业界面的跳转
        Intent intent = new Intent(this, Activity_ch5_2.class);
        startActivity(intent);
    }

    public void ch6Activity(View view){
        //第三次作业页面的跳转
        Intent intent = new Intent(this, Activity_hm3.class);
        startActivity(intent);
    }
}